package com.educate.book.dao;

import java.util.List;

import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import org.springframework.data.mongodb.repository.MongoRepository;
import org.springframework.stereotype.Repository;

import com.educate.book.dao.impl.ChildBookDaoImpl;
import com.educate.book.model.bo.ChildBookBO;
import com.educate.book.model.po.ChildBook;

@Repository
public interface ChildBookDao extends MongoRepository<ChildBook, String> {

    /**
     * #{@link ChildBookDaoImpl#query(ChildBookBO, Pageable)}
     */
    Page<ChildBook> query(ChildBookBO bo, Pageable pageable);
    /**
     * 根据儿童ID，会员ID，绘本ID查询是否已存有书单
     * @param bo
     * @return
     */
    public List<ChildBook> queryByUserIdChildIdBookId(ChildBookBO bo);
}
